﻿
@{
    ViewBag.Title = "提现记录";
    int type = 1;
    string types = Request["type"] ?? "1";
    int.TryParse(Request["type"].ToString(), out type);
    Layout = "~/Views/Shared/_MallLayout.cshtml";
}
<body class="page-fxsBill page-billManage">

    <!-- <div class="lt-head">
        <a href="javascript:history.go(-1);">
            <i class="icon-back fn-left"></i>
        </a>
        <span class="center">提现记录</span>
    </div> -->
    <!--header end-->


    <div class="mod-table mod-tableCenter mt10" id="mescroll">
        <ul>
            <li>
                <div class="td"><div class="tdfirst">金额</div></div>
                <div class="td">时间</div>
                <div class="td">状态</div>
            </li>
        </ul>
        <ul id="wallet"></ul>
    </div>


    <a class="goTop">
        <img src="~/Content/css/tokenmall/img/icon/goTop.png" />
    </a>

    <link href="~/Scripts/mescroll/mescroll.min.css" rel="stylesheet" />
    <script src="~/Scripts/mescroll/mescroll.min.js"></script>
    <script>
        $(function () {

            var mescroll = new MeScroll("mescroll", {
                down: {
                    auto: false,
                    callback: function (mescroll) {
                        mescroll.resetUpScroll(); //下拉刷新的回调,默认重置上拉加载列表为第一页
                    }
                },
                up: {
                    callback: getListData,
                    clearEmptyId: "wallet",
                    isBounce: false,
                    noMoreSize: 3,
                    htmlNodata: '<p class="upwarp-nodata">--没有更多数据了 --</p >',
                    empty: {
                        warpId: "wallet",
                        icon: "",
                        tip: "亲,没有您要找的数据~"

                    },
                    //toTop: {
                    //    src: "/Content/css/tokenmall/img/toup.png",
                    //    html: " <img src='/Content/css/tokenmall/img/toup.png' />",
                    //    offset: 500
                    //}
                }
            });

            function getListData(page) {
                console.log("page.num=" + page.num + ", page.size=" + page.size);
                $.ajax({
                    type: 'post',
                    url: '/MyBill/_Deposited',
                    data: { page: page.num, size: page.size, type:@type },
                    success: function (response) {
                        var paged = $(response).siblings("page");
                        var rows = Number.parseInt(paged.attr("rows"));
                        var total = Number.parseInt(paged.attr("total_result"));
                        mescroll.endBySize(rows, total);
                        if (paged.length === 1) {
                            $("#wallet").append($(response));
                            $('#wallet page').remove();
                        }

                    },
                    error: function (e) {
                        //联网失败的回调,隐藏下拉刷新和上拉加载的状态
                        mescroll.endErr();
                    }
                });
            }
        });
    </script>
</body>

